using System;
using Nop.Core;
using Nop.Core.Domain.ShareBuy;
using System.Collections.Generic;
using Nop.Core.Domain.Customers;

namespace Nop.Services.ShareBuy
{
    /// <summary>
    /// ShareBuy service interface
    /// </summary>
    public partial interface IShareBuyService
    {
        /// <summary>
        /// Deletes a shareBuy
        /// </summary>
        /// <param name="shareBuyItem">ShareBuy item</param>
        void DeleteShareBuy(ShareBuyItem shareBuyItem);

        /// <summary>
        /// Gets a shareBuy
        /// </summary>
        /// <param name="shareBuyId">The shareBuy identifier</param>
        /// <returns>ShareBuy</returns>
        ShareBuyItem GetShareBuyById (int shareBuyId);

        /// <summary>
        /// Gets all shareBuy
        /// </summary>
        /// <param name="dateTo">keyword; null if you want to get all records</param>
        /// <param name="pageIndex">Page index</param>
        /// <param name="pageSize">Page size</param>
        /// <param name="showHidden">A value indicating whether to show hidden records</param>
        /// <returns>ShareBuy items</returns>
        IPagedList<ShareBuyItem> GetShareBuys (string keyword, int pageIndex, int pageSize, bool showHidden = false);

        /// <summary>
        /// Gets the hot shareBuy
        /// </summary>
        /// <returns></returns>
        IPagedList<ShareBuyItem> GetHotShareBuys(int pageIndex, int pageSize, bool showHidden);

        /// <summary>
        /// Inserts a shareBuy item
        /// </summary>
        /// <param name="shareBuy">ShareBuy item</param>
        void InsertShareBuy (ShareBuyItem shareBuy);

        /// <summary>
        /// Updates the shareBuy item
        /// </summary>
        /// <param name="shareBuy">ShareBuy item</param>
        void UpdateShareBuy (ShareBuyItem shareBuy);

        /// <summary>
        /// Check shareBuyVote is exists
        /// </summary>
        /// <param name="shareBuyVote"></param>
        /// <returns></returns>
        bool CheckShareBuyVoteExists(ShareBuyVote shareBuyVote);
        /// <summary>
        /// Insert a sharebuy vote record
        /// </summary>
        /// <param name="shareBuyVote"></param>
        void InsertShareBuyVote (ShareBuyVote shareBuyVote);

        /// <summary>
        /// Get a ShareBuyPicture
        /// </summary>
        /// <param name="shareBuyPictureId"></param>
        ShareBuyPicture GetShareBuyPictureById (int shareBuyPictureId);

        /// <summary>
        /// Delete sharebuy picture
        /// </summary>
        /// <param name="shareBuyPicture"></param>
        void DeleteShareBuyPicture (ShareBuyPicture shareBuyPicture);

        /// <summary>
        ///  Check customer can create share buy or not
        /// </summary>
        /// <param name="customerId"></param>
        /// <param name="orderId"></param>
        /// <param name="productVariantId"></param>
        /// <returns></returns>
        bool CanCreateShareBuy(int customerId,int orderId, int productVariantId);
    }
}
